<!DOCTYPE html>
<html lang="en">
<head>
    <meta name="viewport"
          content="width=device-width,minimum-scale=1.0,maximum-scale=1.0,initial-scale=1.0,user-scalable=no">
    <meta charset="UTF-8">
    <title>click</title>
    <style>
        *{
            margin: 0;
            padding: 0;
        }
        #bg{
            width: 970px;
            height: 1500px;
            margin:auto;
            background: url('img1/bg1.jpg') no-repeat,url('img1/bg2.jpg') no-repeat 0 601px;
            border:1px solid red;
        }
        #bg div{
            width: 401px;
            height: 601px;
        }
    </style>
</head>
<body>
<div id="bg">
    <div>
        <img src="" alt="">
    </div>
</div>
<script>
    var index=0;
    var oDiv=document.querySelectorAll("#bg div")[0];
    var timer;
//    setInterval(function () {
//        index++;
//        index=index%10;
//        document.querySelector('img').src='img/'+index+'.jpg';
//    },100)
    oDiv.onclick=function () {

    }
</script>
</body>
</html>